home *** CD-ROM | disk | FTP | other *** search
- on setCur x,y,cur,reg
- -- Copyright 1995 Interactive Media Design, Inc.
- -- this routine establishes custom cursors for various sprites.
- -- x & y values are start sprite number and end sprite number that
- -- are affected. x may be substituted for a list. ie. [2,7,9] in
- -- this case, y is ignored, but must have a value in that position.
- -- cur - the cursor to be set. They are:
- -- hand, left, right, video, mag, sound, and return
- -- reg - used for tracking what cursors have been set. Value is 1 or 2.
- -- Default value is 2. spriteCur1 list is used for tracking cursors set
- -- within a small section. ie. a few frames. spriteCur2 is used for cursors
- -- that are set for the duration of the movie.
- global spriteCur1, spriteCur2, myCursors, spriteCurTool, spriteCurCust
- if voidP(reg) then
- set reg = 2
- end if
- if reg = "tool" then
- set curList = value("spriteCurTool")
- else if reg = "cust" then
- set curList = value("spriteCurCust")
- else
- set curList = value("spriteCur" & reg)
- end if
- if listP(x) then
- repeat with z in x
- set the cursor of sprite z = getaProp(myCursors,value("#" & cur))
- add value(curList), z
- end repeat
- else
- repeat with z = x to y
- set the cursor of sprite z = getaProp(myCursors,value("#" & cur))
- add value(curList), z
- end repeat
- end if
- end